package com.lazyproject.modules.layer.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.sql.Timestamp;
import java.util.List;

/**
 * @author he_ls
 * @since 2025/1/21 15:44
 **/
@Data
@TableName(value = "layer", autoResultMap = true)
public class Layer {
    private static final long serialVersionUID = 1L;

    private String label;

    private Integer id;

    private Boolean checked;

    private Boolean expanded;

    private Integer parentId;

    private Integer opacity;

    @JsonFormat(
            timezone = "GMT+8",
            pattern = "yyyy-MM-dd HH:mm:ss"
    )
    @DateTimeFormat(
            pattern = "yyyy-MM-dd HH:mm:ss"
    )
    private Timestamp createTime;

    private Boolean disabled;

    private Boolean havePopup;

    private String system;

    private String modelName;

    private Integer sort;

    private String handle;

    private String type;

    private String angle;

    private String positioning;

    private Integer flag;

    private Integer bindId;

    @TableField(exist = false)
    private List<Layer> children;
}
